<script lang="ts" setup>
defineProps({
	icon: {
		type: String,
		required: true
	},
	text: {
		type: String,
		required: true
	}
});
</script>

<template>
	<view class="um-icon-text">
		<view>
			<iconpark-icon :name="icon" v-if="icon"></iconpark-icon>
			<um-image width="40rpx" height="40rpx" v-else></um-image>
		</view>
		<view class="text">{{ text }}</view>
	</view>
</template>

<style lang="scss" scoped>
.um-icon-text {
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	gap: 16rpx;

	.text {
		font-size: 24rpx;
		color: #6a6a6a;
	}
}
</style>
